package com.lin.service.impl;

import com.lin.entity.Admin;
import com.lin.mapper.AdminMapper;
import com.lin.service.AdminService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Qualifier;
import org.springframework.stereotype.Service;

@Service
public class AdminServiceImpl implements AdminService {

    @Autowired
    AdminMapper adminMapper;
    @Override
    public Admin getAdmin(String account) {

       return adminMapper.getAdmin(account);

    }

    @Override
    public Boolean insertAdmin(Admin admin) {
        Integer integer = adminMapper.insertAdmin(admin);

        return integer>0;
    }

    @Override
    public Boolean updateAdmin(Admin admin) {
        Integer integer = adminMapper.updateAdmin(admin);
        return integer>0;
    }


}
